<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>雪儿</title>
    <meta name="viewport" content="width=device-width, initial-scale=1">
</head>
<script src="http://cdn.bootcss.com/jquery/1.12.3/jquery.min.js"></script>
<script src="/layer/layer.js"></script>
<body>
<div style="text-align: center">
    <button id="luckyDraw" style="height: 10em ;width: 10em;margin-top: 50%;">点击抽奖</button>
</div>
</body>
<script>
    $(function () {
        $('#luckyDraw').on('click', function () {
            $.post('', function (res) {
                if (res.code == 200) {
                    layer.alert(res.msg, {icon: 6});
                } else {
                    layer.msg(res.msg, {icon: 5, time: 1000});
                }
            })
        })
    })
</script>
</html>